#ifndef _ADJLISTG_H
#define _ADJLISTG_H

#include <float.h>

#define MAX_NODE_NUM 20
#define INF FLT_MAX

typedef enum { DG, DN, UDG, UDN } GraphType;

typedef struct Arc{
    int head;
    float weight;
    struct Arc * next;
}Arc, *PtArc;

typedef struct{
    char id;
    Arc * adjs;
}Node,AdjList[MAX_NODE_NUM];

typedef struct{
    GraphType type;
    int nodenum,arcnum;
    AdjList nodes;
}GraphS,*Graph;

#endif